ckage p1;

public class Person {
	
	private String name;
	private String surname;
	private String personalcode;
	
	public String getName()
	{
		return name;
	}
	public String getSurname()
	{
		return surname;
	}
	public String getPrCode()
	{
		return personalcode;
	}
	public void setName(String name)
	{
		this.name = name;
	}
	public void setSurname(String surname)
	{
		this.surname = surname;
	}
	public void setPrCode(String personalcode)
	{
		this.personalcode = personalcode;
	}
	public Person()
	{
		setName("noname");
		setSurname("nosurname");
		setPrCode("noperscode");
	}
	public Person(String name, String surname, String perscode)
	{
		setName(name);
		setSurname(surname);
		setPrCode(perscode);
	}
	public String toString()
	{
		StringBuilder StudentString = new StringBuilder();
		StudentString.append(getName()).append(" ").append(getSurname()).append(" ").append(getPrCode());
		String str = new String(StudentString);
		return str;
	}
	

	

}
